import { post } from '@/utils/ajax'

//查询部门列表
export function listDept(query){
    return post('/system/dept/deptTreeList',query);
}

//查询公司列表
export function listCompany(query){
    return post('/system/company/companyTreeList',query);
}

// 懒加载部门列表
export function deptTreeListByParentId(parentId){
    return post('/system/dept/deptTreeListByParentId',{parentId});
}

// 懒加载部门列表
export function deptTreeListByCompanyId(query){
    return post('/system/dept/deptTreeListByCompanyId',query);
}

// 远程搜索部门列表
export function remoteSearchDeptList(query){
    return post('/system/dept/remoteSearchDeptList',query,{noLoading:true});
}

//懒加载查询公司列表
export function companyListByParentId(parentId){
    return post('/system/company/companyListByParentId',{parentId});
}

//远程搜索公司列表
export function remoteSearchCompanyList(companyNameLike){
    return post('/system/company/remoteSearchCompanyList',{companyNameLike},{noLoading:true});
}